<template>
  <div>
    <site-header></site-header>
    <div class="content">
      <tree-menu :treeDataObj="treeDataObj" class="treeMenu"></tree-menu>
      <router-view></router-view>
    </div>
  </div>
</template>

<script>
import siteHeader from "@/components/siteHeader";
import treeMenu from "@/components/treeMenu";
export default {
  name: "App",
  data() {
    return {
      treeDataObj: {
        title: "系统记录",
        data: [
          {
            label: "智能合约分区",
            name: "smartRecord"
          },
          {
            label: "交易记录分区",
            name: "payRecord"
          },
          {
            label: "网格员记录",
            name: "managerRecord"
          },
          {
            label: "网格记录",
            name: "boxRecord"
          },
        ],
      },
    };
  },

  components: {
    treeMenu,
    siteHeader,
  },
  mounted() {},
  methods: {},
  watch: {},
  // 每次更新前都设置
  beforeCreate: function(){
    document.getElementsByTagName("body")[0].className = "smartGrid";
  },
  beforeDestroy: function () {
    document.body.removeAttribute("class", "smartGrid");
  },
};
</script>

<style scoped></style>
